package com.example.whm.model;

import java.io.Serializable;
import java.util.List;

public class ZaoDian extends Entity implements Serializable{
	
	private static final long serialVersionUID = 1523277164157276472L;

	//String pics;
	
	int sell_pri;
	int sell_num;
	int order1_num;
	int order0_num;
	int follow_num;
	int state=1;
	int sub_num;
	int type; // 1-6
	int recommand; //1,0
	int indexp;//1,0
	
	String note;
	String detail;
	List<Detail_M_Item> detail2;
	
	public List<Detail_M_Item> getDetail2() {
		return detail2;
	}



	public void setDetail2(List<Detail_M_Item> detail2) {
		this.detail2 = detail2;
	}    
	
	
	//List<String> comments=new ArrayList<String>();



	/*public List<String> getComments() {
		return comments;
	}



	public void setComments(List<String> comments) {
		this.comments = comments;
	}*/


	
	
	
	
	
	


	


	
	

	public String getDetail() {
		return detail;
	}



	public int getRecommand() {
		return recommand;
	}



	public void setRecommand(int recommand) {
		this.recommand = recommand;
	}



	public int getIndexp() {
		return indexp;
	}



	public void setIndexp(int indexp) {
		this.indexp = indexp;
	}



	public int getAction() {
		return recommand;
	}



	public void setAction(int action) {
		this.recommand = action;
	}



	public int getType() {
		return type;
	}



	public void setType(int type) {
		this.type = type;
	}



	public void setDetail(String detail) {
		this.detail = detail;
	}

	public int getFollow_num() {
		return follow_num;
	}



	public void setFollow_num(int follow_num) {
		this.follow_num = follow_num;
	}



	public String getPre_pic() {
		return pre_pic;
	}



	public void setPre_pic(String pre_pic) {
		this.pre_pic = pre_pic;
	}






	public int getSell_pri() {
		return sell_pri;
	}



	public void setSell_pri(int sell_pri) {
		this.sell_pri = sell_pri;
	}



	public int getSell_num() {
		
		return sell_num;
	}



	public void setSell_num(int sell_num) {
		this.sell_num = sell_num;
	}




	public int getOrder1_num() {
		return order1_num;
	}



	public void setOrder1_num(int order1_num) {
		this.order1_num = order1_num;
	}



	public int getOrder0_num() {
		return order0_num;
	}



	public void setOrder0_num(int order0_num) {
		this.order0_num = order0_num;
	}



	public int getState() {
		return state;
	}



	public void setState(int state) {
		this.state = state;
	}



	public int getLike_num() {
		return like_num;
	}



	public void setLike_num(int like_num) {
		this.like_num = like_num;
	}



	public int getSub_num() {
		return sub_num;
	}



	public void setSub_num(int sub_num) {
		this.sub_num = sub_num;
	}



	public String getNote() {
		return note;
	}



	public void setNote(String note) {
		this.note = note;
	}




	
	
	public ZaoDian() {
		super();
		// TODO Auto-generated constructor stub
	}

	/*@Override
	public boolean containsField(String arg0) {
		// TODO Auto-generated method stub
		//System.out.println("1");
		//System.out.println(arg0);
		return false;
	}

	@Override
	@Deprecated
	public boolean containsKey(String arg0) {
		// TODO Auto-generated method stub
		//System.out.println("2");
		return false;
	}

	@Override
	public Object get(String arg0) {
		// TODO Auto-generated method stub
		//System.out.println("3");
		//System.out.println(arg0);
		return null;
	}

	@Override
	public Set<String> keySet() {
		// TODO Auto-generated method stub
		//System.out.println("4");
		return null;
	}

	@Override
	public Object put(String arg0, Object arg1) {
		
		// TODO Auto-generated method stub
		//System.out.println("==================");
		if (arg0.endsWith("_id")) {
			setId(((ObjectId)arg1).toString()); 
		}
		if (arg0.endsWith("pre_pic")) {
			setPre_pic((String)arg1);
		}
		if (arg0.endsWith("follow_num")) {
			setFollow_num((Integer)arg1);
		}
		if (arg0.endsWith("pics")) {
			setPics((String)arg1);
		}
		if (arg0.endsWith("sell_pri")) {
			setSell_pri((Integer)arg1);
		}
		if (arg0.endsWith("sell_num")) {
			setSell_num((Integer)arg1);
		}
		if (arg0.endsWith("price")) {
			setPrice(Integer.valueOf((String)arg1));
		}
		if (arg0.endsWith("order1_num")) {
			setOrder1_num((Integer)arg1);
		}
		if (arg0.endsWith("order0_num")) {
			setOrder0_num((Integer)arg1);
		}
		if (arg0.endsWith("name")) {
			setName((String)arg1);
		}
		if (arg0.endsWith("state")) {
			setState((Integer)arg1);
		}
		if (arg0.endsWith("like_num")) {
			setLike_num((Integer)arg1);
		}
		if (arg0.endsWith("note")) {
			setNote((String)arg1);
		}
		if (arg0.endsWith("sub_num")) {
			setSub_num((Integer)arg1);
		}
		if (arg0.endsWith("createtime")) {
			
			setCreatetime(((Date)arg1).toLocaleString());
		}
		return null;
	}

	@Override
	public void putAll(BSONObject arg0) {
		// TODO Auto-generated method stub
		System.out.println("6");
	}

	@Override
	public void putAll(Map arg0) {
		// TODO Auto-generated method stub
		System.out.println("7");
	}

	@Override
	public Object removeField(String arg0) {
		// TODO Auto-generated method stub
		System.out.println("8");
		return null;
	}

	@Override
	public Map toMap() {
		// TODO Auto-generated method stub
		System.out.println("9");
		return null;
	}

	@Override
	public boolean isPartialObject() {
		// TODO Auto-generated method stub
		System.out.println("10");
		return false;
	}

	@Override
	public void markAsPartialObject() {
		// TODO Auto-generated method stub
		System.out.println("11");
	}*/

}
